<template>
  <a-form-model :model="form" :label-col="labelCol" :wrapper-col="wrapperCol">
    <a-form-model-item label="标题:">
      <a-input v-model="form.title" />
    </a-form-model-item>
    <a-form-model-item label="路径:">
      <a-input v-model="form.path" />
    </a-form-model-item>
    <a-form-model-item label="重定向:">
      <a-input v-model="form.redirect" />
    </a-form-model-item>
    <a-form-model-item label="打开方式:">
      <a-radio-group v-model="form.resource">
        <a-radio value="1"> Sponsor </a-radio>
        <a-radio value="2"> Venue </a-radio>
      </a-radio-group>
    </a-form-model-item>

    <a-form-model-item :wrapper-col="{ span: 14, offset: 4 }">
      <a-button type="primary" @click="onSubmit"> 修改提交 </a-button>
      <a-button style="margin-left: 10px"> 重置 </a-button>
    </a-form-model-item>
  </a-form-model>
</template>
<script>
export default {
  data() {
    return {
      labelCol: { span: 4 },
      wrapperCol: { span: 14 },
      form: {
        name: '',
        region: undefined,
        date1: undefined,
        delivery: false,
        type: [],
        resource: '',
        desc: '',
      },
    }
  },
  methods: {
    onSubmit() {
      console.log('submit!', this.form)
    },
  },
}
</script>

